<?php
/* @var $this AccountsController */
/* @var $model Accounts */
/* @var $form CActiveForm */
?>

<div class="grid-24">
	<div class="widget">
		<div class="widget-header">
			<span
				class="<?php if (sizeof($searchData) > 0) { ?>icon-minus-alt<?php } else { ?>icon-plus-alt<?php } ?>"
				id="search_icon" onclick="return commonFn.searchForm()"></span>
			<h3>
			<?php echo Yii::t('main', 'form.search'); ?>
			</h3>
		</div>
		<!-- .widget-header -->
		<div class="widget-content" style="<?php if (sizeof($searchData) == 0) { ?>display: none;<?php }; ?>" id="search_form">
		<?php
		$form = $this->beginWidget('CActiveForm', array(
          'action' => Yii::app()->createUrl($this->route),
          'method' => 'get',
          'htmlOptions' => array('class' => 'form uniformForm validateForm'),
		));
		?>

			<div class="field-group">
			<?php echo $form->label($model,'account_id'); ?>
				<div class="field">
				<?php echo $form->textField($model,'account_id'); ?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'name'); ?>
				<div class="field">
				<?php echo $form->textField($model,'name',array('size'=>60,'maxlength'=>128)); ?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'member_id'); ?>
				<div class="field">
				<?php $memberId = (isset($searchData['member_id'])) ? $searchData['member_id'] : ''?>
				<?php echo $form->textField($model,'member_id', array('value' => $memberId)); ?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'site_id'); ?>
				<div class="field">
				<?php $siteId = (isset($searchData['site_id'])) ? $searchData['site_id'] : ''?>
				<?php echo CHtml::dropDownList('site_id', $siteId, $siteList, array('empty' => 'All'))?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'status'); ?>
				<div class="field">
				<?php $status = (isset($searchData['status'])) ? $searchData['status'] : ''?>
				<?php echo CHtml::dropDownList('status', $status, $statusList, array('empty' => 'All'))?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'ad_status'); ?>
				<div class="field">
				<?php $ad = (isset($searchData['ad_status'])) ? $searchData['ad_status'] : ''?>
				<?php echo CHtml::dropDownList('ad_status', $ad, $adStatus, array('empty' => 'All'))?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'grid_status'); ?>
				<div class="field">
				<?php $grid = (isset($searchData['grid_status'])) ? $searchData['grid_status'] : ''?>
				<?php echo CHtml::dropDownList('grid_status', $grid, $gridStatus, array('empty' => 'All'))?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'money_total'); ?>
				<div class="field">
				<?php echo $form->textField($model,'money_total'); ?>
				</div>
			</div>

			<div class="field-group">
			<?php echo $form->label($model,'money_current'); ?>
				<div class="field">
				<?php echo $form->textField($model,'money_current'); ?>
				</div>
			</div>


			<div class="field-group">
			<?php echo $form->label($model,'mac_address'); ?>
			<?php echo $form->textField($model,'mac_address',array('size'=>60,'maxlength'=>255)); ?>
			</div>

			<div class="field-groups">
				<button class="btn btn-primary btn-small" type="submit">
					<span class="icon-loop"></span>Tìm kiếm
				</button>
			</div>

			<?php $this->endWidget(); ?>
		</div>
	</div>
</div>
